added samples
[windows-sources.git] / sdk / samples / all in on code / Visual Studio 2008 / VBXslTransformXml / Books.xslt
blob661f05ad95dbcf61645389120b1d3707683ce5c9
1 <?xml version="1.0" encoding="utf-8"?>
2 <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
3     xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl"
5     <xsl:output method="text"/>
7     <xsl:template match="catalog">
8       <xsl:apply-templates select ="book"/>
9     </xsl:template>
11     <xsl:template match="book">
12       <xsl:text>&#34;</xsl:text>
13       <xsl:value-of select ="@id"/>
14       <xsl:text>&#34;</xsl:text>
15       <xsl:value-of select ="','"/>
16       <xsl:for-each select ="*">
17         <xsl:text>&#34;</xsl:text>
18         <xsl:value-of select ="."/>
19         <xsl:text>&#34;</xsl:text>
20         <xsl:if test ="position() != last()">
21           <xsl:value-of select ="','"/>
22         </xsl:if>
23       </xsl:for-each>
24       <xsl:text>&#xD;&#xa;</xsl:text>
25     </xsl:template>
26 </xsl:stylesheet>